import 'package:json_annotation/json_annotation.dart';

part 'mymessages_bean.g.dart';


@JsonSerializable()
class MymessagesBean extends Object with _$MymessagesBeanSerializerMixin{

  @JsonKey(name: 'msg')
  String msg;

  @JsonKey(name: 'code')
  String code;

  @JsonKey(name: 'result')
  List<Result> result;

  @JsonKey(name: 'pageNumber')
  int pageNumber;

  @JsonKey(name: 'totalPages')
  int totalPages;

  @JsonKey(name: 'pageSize')
  int pageSize;

  MymessagesBean(this.msg,this.code,this.result,this.pageNumber,this.totalPages,this.pageSize,);

  factory MymessagesBean.fromJson(Map<String, dynamic> srcJson) => _$MymessagesBeanFromJson(srcJson);

}


@JsonSerializable()
class Result extends Object with _$ResultSerializerMixin{

  @JsonKey(name: 'page')
  int page;

  @JsonKey(name: 'pageSize')
  int pageSize;

  @JsonKey(name: 'totalRecords')
  int totalRecords;

  @JsonKey(name: 'id')
  int id;

  @JsonKey(name: 'userId')
  int userId;

  @JsonKey(name: 'content')
  String content;

  @JsonKey(name: 'title')
  String title;

  @JsonKey(name: 'type')
  int type;

  @JsonKey(name: 'messageStatus')
  int messageStatus;

  @JsonKey(name: 'creatTime')
  String creatTime;

  @JsonKey(name: 'totalPages')
  int totalPages;

  @JsonKey(name: 'firstIndex')
  int firstIndex;

  @JsonKey(name: 'lastPageNo')
  int lastPageNo;

  @JsonKey(name: 'previousPageNo')
  int previousPageNo;

  @JsonKey(name: 'nextPageNo')
  int nextPageNo;

  @JsonKey(name: 'limit')
  int limit;

  @JsonKey(name: 'start')
  int start;

  Result(this.page,this.pageSize,this.totalRecords,this.id,this.userId,this.content,this.title,this.type,this.messageStatus,this.creatTime,this.totalPages,this.firstIndex,this.lastPageNo,this.previousPageNo,this.nextPageNo,this.limit,this.start,);

  factory Result.fromJson(Map<String, dynamic> srcJson) => _$ResultFromJson(srcJson);

}